"""
    员工新增接口类
"""
import time

import requests

from config import BASE_URL
from tools.get_header import get_header





class EmpAddApi:
    @classmethod
    def emp_add(cls,json_data):
        emp_add_url = BASE_URL+"emps"
        resp = requests.post(emp_add_url,headers=get_header(),json= json_data)
        return resp




if __name__ == '__main__':
    data = {
    "username":"zhaodonglai",
    "name":"赵东来",
    "gender":1,
    "job":3,
    "entrydate": "2013-09-05",
    "dept_id":1
    }
    print(EmpAddApi.emp_add(data).json())